-- GENERATED SPELL FOR [Scarshield Sentry] --


function spell0_9044(pUnit, Event) --@Multi-Shot,n/a--
pUnit:FullCastSpellOnTarget(14443,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_9044', 629, 1)
end

function spell1_9044(pUnit, Event) --@Shoot,n/a--
pUnit:FullCastSpellOnTarget(6660,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_9044', 555, 1)
end

function spell2_9044(pUnit, Event) --@Slowing Poison,n/a--
pUnit:FullCastSpellOnTarget(14897,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_9044', 25278, 1)
end

function Sorts_9044(pUnit, Event)
local choix_sorts_9044 = math.random(0, 2)
if choix_sorts_9044 == 0 then
pUnit:RegisterEvent('spell0_9044', 1, 1)
end
if choix_sorts_9044 == 1 then
pUnit:RegisterEvent('spell1_9044', 1, 1)
end
if choix_sorts_9044 == 2 then
pUnit:RegisterEvent('spell2_9044', 1, 1)
end
end

function mob9044_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_9044', math.random(1500, 3000), 1)
end

function mob9044_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob9044_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob9044_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(9044, 1, 'mob9044_Action')
RegisterUnitEvent(9044, 2, 'mob9044_Leave')
RegisterUnitEvent(9044, 3, 'mob9044_Kill')
RegisterUnitEvent(9044, 4, 'mob9044_Die')
